-
Notifications
You must be signed in to change notification settings - Fork 558
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
phi 4 multimodal training version 1 ( with limitations ) #1555
Conversation
src/oumi/datasets/chat_templates/phi4-multimodal-instruct.jinja
Outdated
Show resolved
Hide resolved
@override | ||
def ignore_features(self) -> list[str]: | ||
"""Returns a list of keys of features to ignore from feeding the model.""" | ||
return self._ignore_features if self._ignore_features else [] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Consider returning a shallow copy. Just to make sure that external users can't mutate our member variables.
return copy.copy(self._ignore_features) if self._ignore_features else []
@@ -75,6 +79,7 @@ def __init__( | |||
self._worker_processor.image_processor | |||
) | |||
self._label_ignore_index: Optional[int] = label_ignore_index | |||
self._ignore_features: Optional[list[str]] = ignore_features |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Consider making our own private copy. Just to make sure that external users can't mutate our member variable.
self._ignore_features: Optional[list[str]] = copy.copy(ignore_features) if ignore_features else []
Description
Adds the necessary changes for SFT training (vision/text-only) with phi-4 in Oumi.
Given that we are using here the
vision_language_with_padding
we are limited to size batch 1, and we cannot accommodate multi-image training.Related issues
Towards OPE-1102
Before submitting
Reviewers
At least one review from a member of
oumi-ai/oumi-staff
is required.